<template>
	<view class="container">
		<uni-list>
			<uni-list-item showExtraIcon="true" :extraIcon="{type: 'person-filled'}" title="昵称"
				:rightText="user.nickname" />
			<uni-list-item showExtraIcon="true" :extraIcon="{type: 'phone-filled'}" title="姓名"
				:rightText="user.readname" />
			<uni-list-item showExtraIcon="true" :extraIcon="{type: 'email-filled'}" title="性别" :rightText="user.sex" />
			<uni-list-item showExtraIcon="true" :extraIcon="{type: 'phone-filled'}" title="手机"
				:rightText="user.phone" />
			<uni-list-item showExtraIcon="true" :extraIcon="{type: 'email-filled'}" title="邮箱"
				:rightText="user.email" />
			<uni-list-item showExtraIcon="true" :extraIcon="{type: 'info'}" title="个人介绍"
				:rightText="user.memo" />
		</uni-list>
		<button type="primary" @click="gotoEdit">编辑资料</button>
	</view>
</template>

<script>
	export default {
		data() {
			return {
				user:uni.getStorageSync('loginUser'),
			}
		},
		onLoad() {

		},
		methods: {
			gotoEdit() {
				// 跳转到编辑资料页面
				uni.navigateTo({
					url: `/pages/userinfo/edituserinfo/edituserinfo`
				});
			}
		}
	}
</script>

<style lang="scss">
	page {
		background-color: #ffffff;
	}
</style>